<!DOCTYPE stack PUBLIC "-//Apple, Inc.//DTD stack V 2.0//EN" "" >
<stack>
<name>in</name>
<id>-1</id>
<cardCount>5</cardCount>
<cardID>4735</cardID>
<listID>3646</listID>
<cantModify><false /></cantModify>
<cantDelete><true /></cantDelete>
<cantAbort><false /></cantAbort>
<cardSize>
<width>512</width>
<height>342</height>
</cardSize>
<script>--SIN LAWon sasb -- find sa from sbglobal aa,ab,ac,sa,sb,scput sb*sin(pi*aa/180)/sin(pi*ab/180) into saend sasbon sasc -- find sa from scglobal aa,ab,ac,sa,sb,scput sc*sin(pi*aa/180)/sin(pi*ac/180) into saend sascon sbsa -- find sb from saglobal aa,ab,ac,sa,sb,scput sa*sin(pi*ab/180)/sin(pi*aa/180) into sbend sbsaon sbsc -- find sb from scglobal aa,ab,ac,sa,sb,scput sc*sin(pi*ab/180)/sin(pi*ac/180) into sbend sbscon scsa -- find sc from saglobal aa,ab,ac,sa,sb,scput sa*sin(pi*ac/180)/sin(pi*aa/180) into scend scsaon scsb --find sc from sbglobal aa,ab,ac,sa,sb,scput sb*sin(pi*ac/180)/sin(pi*ab/180) into scend scsb--COS LAWon aasides -- find aa from all sidesglobal aa,ab,ac,sa,sb,scput ((sb^2)+(sc^2)-(sa^2))/(2*sb*sc) into cosaput sqrt(1-cosa^2) into sinaput (180/pi)*atan(sina/cosa) into aaif aa<0 then put 180+aa into aaend aasideson absides -- find ab from all sidesglobal aa,ab,ac,sa,sb,scput ((sa^2)+(sc^2)-(sb^2))/(2*sa*sc) into cosbput sqrt(1-cosb^2) into sinbput (180/pi)*atan(sinb/cosb) into abif ab<0 then put 180+ab into abend absideson acsides -- find ac from sidesglobal aa,ab,ac,sa,sb,scput ((sa^2)+(sb^2)-(sc^2))/(2*sa*sb) into coscput sqrt(1-cosc^2) into sincput (180/pi)*atan(sinc/cosc) into acif ac<0 then put 180+ac into acend acsideson saaa -- find sa from 2 sides and enclosed angle aaglobal aa,ab,ac,sa,sb,scput sqrt((sb^2)+(sc^2)-(2*sb*sc*cos(pi*aa/180))) into saend saaaon sbab -- find sb from 2 sides and enclosed angle abglobal aa,ab,ac,sa,sb,scput sqrt((sa^2)+(sc^2)-(2*sa*sc*cos(pi*ab/180))) into sbend sbabon scac -- find sc from 2 sides and enclosed angle acglobal aa,ab,ac,sa,sb,scput sqrt((sa^2)+(sb^2)-(2*sa*sb*cos(pi*ac/180))) into scend scacon scaa -- find sc from sides sa,sb and angle aa (2 Solutions)global aa,ab,ac,sa,sb,sc,ktemp,kkput (sb*cos(pi*aa/180))+(sqrt(((sb*cos(pi*aa/180))^2)-(sb^2)+(sa^2))) into scput (sb*cos(pi*aa/180))-(sqrt(((sb*cos(pi*aa/180))^2)-(sb^2)+(sa^2))) into ktempif ktemp > 0 then put 1 into kkend scaaon saab -- find sa from sides sb,sc and angle ab (2 Solutions)global aa,ab,ac,sa,sb,sc,ktemp,kkput (sc*cos(pi*ab/180))+(sqrt(((sc*cos(pi*ab/180))^2)-(sc^2)+(sb^2))) into saput (sc*cos(pi*ab/180))-(sqrt(((sc*cos(pi*ab/180))^2)-(sc^2)+(sb^2))) into ktempif ktemp > 0 then put 1 into kkend saabon sbac -- find sb from sides sc,sa and angle ac (2 Solutions)global aa,ab,ac,sa,sb,sc,ktemp,kkput (sa*cos(pi*ac/180))+(sqrt(((sa*cos(pi*ac/180))^2)-(sa^2)+(sc^2))) into sbput (sa*cos(pi*ac/180))-(sqrt(((sa*cos(pi*ac/180))^2)-(sa^2)+(sc^2))) into ktempif ktemp > 0 then put 1 into kkend sbacon sbaa -- find sb from sides sc,sa and angle aa (2 Solutions)global aa,ab,ac,sa,sb,sc,ktemp,kkput (sc*cos(pi*aa/180))+(sqrt(((sc*cos(pi*aa/180))^2)-(sc^2)+(sa^2))) into sbput (sc*cos(pi*aa/180))-(sqrt(((sc*cos(pi*aa/180))^2)-(sc^2)+(sa^2))) into ktempif ktemp > 0 then put 1 into kkend sbaaon scab -- find sc from sides sa,sb and angle ab (2 Solutions)global aa,ab,ac,sa,sb,sc,ktemp,kkput (sa*cos(pi*ab/180))+(sqrt(((sa*cos(pi*ab/180))^2)-(sa^2)+(sb^2))) into scput (sa*cos(pi*ab/180))-(sqrt(((sa*cos(pi*ab/180))^2)-(sa^2)+(sb^2))) into ktempif ktemp > 0 then put 1 into kkend scabon saac -- find sa from sides sb,sc and angle ac (2 Solutions)global aa,ab,ac,sa,sb,sc,ktemp,kkput (sb*cos(pi*ac/180))+(sqrt(((sb*cos(pi*ac/180))^2)-(sb^2)+(sc^2))) into saput (sb*cos(pi*ac/180))-(sqrt(((sb*cos(pi*ac/180))^2)-(sb^2)+(sc^2))) into ktempif ktemp > 0 then put 1 into kkend saacon storemainglobal aa,ab,ac,sa,sb,scset numberformat to "0.0000"put aa into line 1 of card field 9put ab into line 2 of card field 9put ac into line 3 of card field 9put sa into line 4 of card field 9put sb into line 5 of card field 9put sc into line 6 of card field 9end storemainon storesolutionglobal aa,ab,ac,sa,sb,scset numberformat to "0.0000"put aa into line 7 of card field 9put ab into line 8 of card field 9put ac into line 9 of card field 9put sa into line 10 of card field 9put sb into line 11 of card field 9put sc into line 12 of card field 9end storesolutionon retrieveglobal aa,ab,ac,sa,sb,sc,kaa,kab,kac,ksa,ksb,kscput line 1 of card field 9 into aaput line 2 of card field 9 into abput line 3 of card field 9 into acput line 4 of card field 9 into saput line 5 of card field 9 into sbput line 6 of card field 9 into scput line 7 of card field 9 into kaaput line 8 of card field 9 into kabput line 9 of card field 9 into kacput line 10 of card field 9 into ksaput line 11 of card field 9 into ksbput line 12 of card field 9 into kscend retrieveon calculateglobal cc,ii,aa,ab,ac,sa,sb,sc,ktemp,kk,kaa,kab,kac,ksa,ksb,ksc,maxput 0 into ffput 0 into kkput 0 into ggput 0 into kmaxput empty into card field 12put empty into card field 7put empty into card field 8-- 3 angles-----------if ii=2 and sa>0 and ff=0 thensbsascsaput 1 into ffend ifif ii=2 and sb>0 and ff=0 thensasbscsbput 1 into ffend ifif ii=2 and sc>0 and ff=0 thensbscsascput 1 into ffend ifif ii=2 and ff=0 thenput 1 into sasbsascsaput 1 into ggput 1 into ffend if-- 3 sides-----------if (sa>0 and sb>0 and sc>0 and ff=0) or cc=3 thenaasidesabsidesput 180-aa-ab into acput 1 into ffend if-- 1 angle between 2 sides----------------------------if aa>0 and sb>0 and sc>0 and ff=0 thensaaaabsidesput 180-aa-ab into acput 1 into ffend ifif ab>0 and sa>0 and sc>0 and ff=0 thensbabaasidesput 180-aa-ab into acput 1 into ffend ifif ac>0 and sa>0 and sb>0 and ff=0 thenscacaasidesput 180-aa-ac into abput 1 into ffend if-- 1 angle not between 2 sides (sides are counterclockwise from angle)----------------------------------------------------------------------if aa>0 and sb>0 and sa>0 and ff=0 thenscaaabsidesput 180-aa-ab into acif kk=1 thenstoremainput ktemp into scabsidesput 180-aa-ab into acstoresolutionretrieveput empty into card field 9end ifput 1 into ffend ifif ab>0 and sc>0 and sb>0 and ff=0 thensaabacsidesput 180-ab-ac into aaif kk=1 thenstoremainput ktemp into saacsidesput 180-ab-ac into aastoresolutionretrieveput empty into card field 9end ifput 1 into ffend ifif ac>0 and sa>0 and sc>0 and ff=0 thensbacaasidesput 180-ac-aa into abif kk=1 thenstoremainput ktemp into sbaasidesput 180-ac-aa into abstoresolutionretrieveput empty into card field 9end ifput 1 into ffend if-- 1 angle not between 2 sides (sides are clockwise from angle)----------------------------------------------------------------if aa>0 and sa>0 and sc>0 and ff=0 thensbaaabsidesput 180-aa-ab into acif kk=1 thenstoremainput ktemp into sbabsidesput 180-aa-ab into acstoresolutionretrieveput empty into card field 9end ifput 1 into ffend ifif ab>0 and sb>0 and sa>0 and ff=0 thenscabacsidesput 180-ab-ac into aaif kk=1 thenstoremainput ktemp into scacsidesput 180-ab-ac into aastoresolutionretrieveput empty into card field 9end ifput 1 into ffend ifif ac>0 and sc>0 and sb>0 and ff=0 thensaacaasidesput 180-ac-aa into abif kk=1 thenstoremainput ktemp into saaasidesput 180-ac-aa into abstoresolutionretrieveput empty into card field 9end ifput 1 into ffend if--*****--- results-------------------if offset("N",sa&sb&sc&aa&ab&ac)<>0 or min(sa,sb,sc,aa,ab,ac)<0 thenplay "boing"put "Error... These values do not give a real solution"wait 80hide message boxexit calculateend ifput (sa+sb+sc)/2 into sput sqrt(s*(s-sa)*(s-sb)*(s-sc)) into areaset numberformat to "0.0000"put "angle A=" into line 2 of card field 12put 1*aa&"°" into line 2 of card field 7put "angle B=" into line 3 of card field 12put 1*ab&"°" into line 3 of card field 7put "angle C=" into line 4 of card field 12put 1*ac&"°" into line 4 of card field 7if gg=0 thenput "side AB=" into line 6 of card field 12put 1*sc into line 6 of card field 7put "side BC=" into line 7 of card field 12put 1*sa into line 7 of card field 7put "side CA=" into line 8 of card field 12put 1*sb into line 8 of card field 7put "Area =" into line 10 of card field 12put area into line 10 of card field 7end ifif aa=90 or ab=90 or ac=90 then put 0 into kkif kk=1 thenput "Solution 1" into line 1 of card field 7put "Solution 2" into line 1 of card field 8put 1*kaa into line 2 of card field 8put 1*kab into line 3 of card field 8put 1*kac into line 4 of card field 8put 1*ksc into line 6 of card field 8put 1*ksa into line 7 of card field 8put 1*ksb into line 8 of card field 8put (ksa+ksb+ksc)/2 into ksput sqrt(ks*(ks-ksa)*(ks-ksb)*(ks-ksc)) into line 10 of card field 8end ifif offset("N",sa&sb&sc&aa&ab&ac)<>0 or min(sa,sb,sc,aa,ab,ac)<0 thenplay "boing"put "Error... These values do not give a real solution"wait 80hide message boxexit calculateend if----put 210 into scaleput sc into maxhif aa>90 then put sc+(sb*cos(pi*(180-aa)/180)) into maxhif ab>90 then put sc+(sa*cos(pi*(180-ab)/180)) into maxhput sa*sin(pi*ab/180) into maxvif ab>90 then put sa*sin(pi*(180-ab)/180) into maxvif maxh>=maxv then put maxh into maxif maxv>maxh then put maxv into maxput scale/max into ratioput round(ratio*maxh) into maxhput round(ratio*maxv) into maxvput round(sa*ratio) into rsaput round(sb*ratio) into rsbput round(sc*ratio) into rscput 35 into Bhif ab>90 then put round(30+maxh-rsc) into Bhput 285 into Bvput Bh+rsc into Ahput 285 into Avput round(Bh+rsc-rsb*cos(pi*aa/180)) into Chput round(Av-rsb*sin(pi*aa/180)) into CvChoose select toolDrag from 17,50 to 253,302domenu clear picturechoose line toolset linesize to 2drag from Bh,Bv to Ah,Avdrag from Ah,Av to Ch,Cvdrag from Ch,Cv to Bh,Bvif kk<>0 thenset linesize to 1if card field 4>0 and sc>ksc thenput Ah-round((ksc/sc)*(Ah-Bh)) into temphput Av into tempvdrag from temph,tempv to Ch,Cvsubtract 4 from tempvadd 1 to temphend ifif card field 5>0 and sa>ksa thenadd 1 to kkput sqrt(((Ch-Bh)^2)+((Cv-Bv)^2))*ksa/sa into tempput Bh+round(temp*cos(pi*ab/180)) into temphput Bv-round(temp*sin(pi*ab/180)) into tempvdrag from temph,tempv to Ah,Avsubtract 5 from temphadd 13 to tempvend ifif card field 6>0 and sb>ksb thenadd 2 to kkput (sqrt(((Ch-Ah)^2)+((Cv-Av)^2))*ksb/sb) into tempput Ch+round(temp*cos(pi*aa/180)) into temphput Cv+round(temp*sin(pi*aa/180)) into tempvdrag from temph,tempv to Bh,Bvadd 16 to tempvadd 6 to temphend ifif card field 4>0 and sb>ksb thenadd 3 to kkput (sqrt(((Ch-Ah)^2)+((Cv-Av)^2))*(1-(ksb/sb))) into tempput Ch+round(temp*cos(pi*aa/180)) into temphput Cv+round(temp*sin(pi*aa/180)) into tempvdrag from temph,tempv to Bh,Bvadd 13 to tempvsubtract 3 from temphend ifif card field 5>0 and sc>ksc thenadd 4 to kkput Bh+round((ksc/sc)*(Ah-Bh)) into temphput Av into tempvdrag from temph,tempv to Ch,Cvsubtract 4 from tempvsubtract 10 from temphend ifif card field 6>0 and sa>ksa thenadd 5 to kkput (sqrt(((Ch-Bh)^2)+((Cv-Bv)^2))*(1-(ksa/sa))) into tempput Bh+round(temp*cos(pi*ab/180)) into temphput Bv-round(temp*sin(pi*ab/180)) into tempvdrag from temph,tempv to Ah,Avadd 14 to tempvsubtract 2 from temphend ifend ifChoose text toolset textfont to chicagoset textsize to 12click at Bh-15,Bv+15Type "B°"click at Ah-10,Av+15type "A°"click at Ch-7,Cv-5type "C°"click at 0,0if kk<>0 thenset textfont to genevaset textsize to 9click at temph,tempvif kk=1 or kk=6 then type "B°"if kk=2 or kk=4 then type "C°"if kk=3 or kk=5 then type "A°"end ifchoose browse toolset cursor to 1end calculateon resetrepeat with x=1 to 6put empty into card field xend rep